package com.mogu_soup.util;

import java.awt.*;


/**
 * Version: 2.1
 * Author: TangJun
 * Date: 2024-08-02
 * Note: 存放游戏所需的所有常量数据，每次静态导入后可直接使用
 */

public class Constant {
    /************************游戏窗口数据*********************************/
    public static final String FRAME_TITLE = "坦克大战破解版";//窗口标题

    public static final int FRAME_WIDTH = 1700;//窗口宽度
    public static final int FRAME_HEIGHT = 1200;//窗口高度
    public static final Font FRAME_FONT = new Font("楷体", Font.BOLD, 60);//窗口字体
    public static final Font NAME_FONT = new Font("楷体", Font.BOLD, 20);//坦克名字字体
    public static final Font HINT_FONT = new Font("黑体", Font.BOLD, 15);//暴击提示字体
    public static final Font OVER_FONT = new Font("黑体", Font.BOLD, 30);//提示字体
    public static final Font INFO_FONT = new Font("黑体", Font.BOLD, 60);//信息栏字体
    public static final Font HELP_FONT_BIG = new Font("楷体", Font.BOLD, 50);//帮助信息字体
    public static final Font HELP_FONT_SMALL = new Font("楷体", Font.BOLD, 35);//帮助信息字体




    public static final int SCREEN_WIDTH = Toolkit.getDefaultToolkit().getScreenSize().width;//屏幕宽度
    public static final int SCREEN_HEIGHT = Toolkit.getDefaultToolkit().getScreenSize().height;//屏幕高度
    public static final int FRAME_X = SCREEN_WIDTH - FRAME_WIDTH >>> 1;//窗口x坐标
    public static final int FRAME_Y = SCREEN_HEIGHT - FRAME_HEIGHT >>> 1;//窗口y坐标

    /************************游戏菜单数据*********************************/
    public static final int STATE_INIT= 0;//初始化状态
    public static final int STATE_RUN = 1;//游戏运行状态
    public static final int STATE_HELP = 2;//游戏帮助状态
    public static final int STATE_ABOUT = 3;//游戏关于状态
    public static final int STATE_OVER = 4;//游戏结束状态
    public static final int STATE_WIN = 5;//游戏胜利状态
    public static final int STATE_CROSS = 6;//游戏切关卡

    public static final String[] MENU = new String[]{
            "开始游戏",
            "继续游戏",
            "游戏帮助",
            "游戏关于",
            "退出游戏"
    };
    public static final int FPS = 60;//帧数

    /************************游戏运行数据*********************************/
    public static final int ENEMY_MAX_NUM = 5;//最大敌人数量
    public static final int ENEMY_BORN_INTERVAL = 8000;//敌人生成间隔
    public static final int ENEMY_MOVE_INTERVAL = 100;//敌人移动间隔
    public static final int ENEMY_DIRECTION_INTERVAL = 3000;//敌人变向间隔
    public static final double ENEMY_FIRE_PROBABILITY = 0.1;//敌人开火概率

    public static final int FIRE_INTERVAL = 100;//我方开火间隔
    public static final double CRITICAL_PROBABILITY = 0.5;//暴击率

    //名字
    public static final String[] NAMES = {
            "狮子","老虎","大象","猴子","鳄鱼",
            "兔子","海豚","企鹅","蟒蛇","乌龟",
            "鹦鹉","蜜蜂","海龟","鲸鱼","熊猫",
            "狐狸","绵羊","猫咪","猎狗","黑马"};
    //形容词
    public static final String[] MODIFY = {
            "美丽的", "快速的", "安静的", "明亮的", "温暖的",
            "强大的", "幸福的", "复杂的", "简单的", "友好的",
            "神秘的", "古老的", "新鲜的", "有趣的", "漂亮的",
            "忙碌的", "甜美的", "高大的", "细腻的", "勇敢的"
    };
    //暴击提示
    public static final String CRITICAL_STRIKE = "被暴击！！";
    public static final String OVER_STR0 = "Esc键退出游戏";
    public static final String OVER_STR1 = "Enter键重新开始";
    public static final String HINT_STR = "任意键返回";
    public static final String HELP_STR0 = "游戏帮助";
    public static final String HELP_STR1 = "WASD或方向键上下移动";
    public static final String HELP_STR2 = "只有砖块可摧毁，可以利用草丛躲起来";
    public static final String ABOUT_STR0 = "游戏关于";
    public static final String ABOUT_STR1 = "版权：唐俊";
    public static final String ABOUT_STR2 = "邮箱：t2227456239@163.com";

    /************************游戏窗口图片数据*********************************/

    //游戏封面
    public static Image FRAME_BACKGROUND = MyUtil.createImage("resource\\other\\frame_background.jpg");
    //游戏背景
    public static Image GAME_BACKGROUND = MyUtil.createImage("resource\\other\\game_background.jpeg");
    //游戏标题
    public static Image GAME_TITLE = MyUtil.createImage("resource\\other\\title.png");
    //游戏结束
    public static Image GAME_OVER = MyUtil.createImage("resource\\other\\game_over.png");
    //游戏胜利
    public static Image GAME_WIN = MyUtil.createImage("resource\\other\\game_win.png");
}
